from django.conf.urls import url

from apps.users import views
from apps.users.views import UsernameCountView, MobilesCountView, LoginView

urlpatterns = [
    url(r'^register/$', views.RegisterView.as_view()),  # 引入主页的url配置
    url(r'^usernames/(?P<username>[a-zA-Z0-9_]{5,20})/count/$', UsernameCountView.as_view(), name='count'),
    url(r'^mobiles/(?P<mobile>1[3-9]\d{9})/count/$', MobilesCountView.as_view(), name='count_mobile'),
    url(r'^login/$', LoginView.as_view(), name='login'),

]
